Conventional lossless data compression methods use algorithms to compress an original data item such as, e.g., machine executable code, having a given length measured in bits, into a compressed representation of the data, which may include less than the original amount of bits. The compressed representation allows reconstruction of the original data item with no loss of information.
Some lossless data compression methods may include a probability-based encoding scheme, e.g., Huffman encoding, to encode input data into a unique bit sequence, eg., a binary encoding, in such a way that data subsequences having a higher recurrence probability are associated with a shorter binary encoding. An encoding algorithm may rely on a statistical model of the input data type, which may include, for example, a dictionary having entries that correspond to subsequences, or words, of high recurrence probability.
Reducing the size of the compressed code, i.e., improving the compression ratio, may allow more data to be stored in a limited memory space, resulting in reduced storage costs and/or faster execution performance times.
It will be appreciated that for simplicity and clarity of illustration, elements shown in the figures have not necessarily been drawn to scale. For example, the dimensions of some of the elements may be exaggerated relative to other elements for clarity. Further, where considered appropriate, reference numerals may be repeated among the figures to indicate corresponding or analogous elements.